Autotitrating method and apparatus

ABSTRACT

An apparatus and method of controlling the delivery of therapeutic gas delivered to a patient undergoing positive airway pressure therapy is described. The method includes providing a flow of gas to a patient&#39;s airway at a pressure, obtaining information from the range of 0 to 25 Hz of the frequency domain of the flow, and adjusting the pressure based on the information. The apparatus includes a blower for providing a flow of gas to a patient&#39;s airway at a pressure, a sensor to measure a characteristic of the flow, a controller to obtain information from the range of 0 to 25 Hz of the frequency domain of the characteristic, and a pressure regulator for adjusting the pressure based on the information.

CROSS REFERENCE TO RELATED APPLICATION

This application is a continuation of U.S. patent application Ser. No. 12/983,584, filed Jan. 3, 2011, which is a continuation of U.S. patent application Ser. No. 11/198,072, filed Aug. 5, 2005 and issued as U.S. Pat. No. 7,882,834, which claims the benefit of U.S. provisional patent application Ser. No. 60/599,356, filed on Aug. 6, 2004. The disclosure of each of these prior applications is incorporated herein by reference in its entirety.

FIELD

This invention is generally directed to a method and apparatus for controlling the positive air pressure applied to a patient undergoing positive airway pressure therapy.

BACKGROUND

Obstructions in some patients' airways during sleep can cause limited airflow, leading to apnea, hypopnea, or snoring. The obstruction is often a collapsed pharynx. The obstruction may be a partial airway obstruction, leading to altered characteristics of the airflow. A hyperpnoea is a reduction of flow that is greater than fifty percent, but not complete. An apnea, however, is a complete cessation of airflow. Each of these conditions frequently leads to sleep deprivation.

It is well known to treat patients suffering from sleep deprivation with positive airway pressure therapy (“PAP”). This therapy can be Continuous Positive Airway Pressure (“CPAP”), Variable Positive Airway Pressure (“VPAP”), Bi-level Positive Airway Pressure (“BiPAP”), or any of numerous other forms of respiratory therapy. The application of positive pressure to the patient's pharynx helps minimize or prevent this collapse. Positive airway pressure therapy is currently applied by means of an apparatus containing a pressure source, typically a blower, through a tube to a mask, which the patient wears in bed.

It is desired to control the applied pressure. Too little pressure tends not to solve the problem. Too much pressure tends to cause discomfort to the patient, such as drying out of the mouth and pharynx, as well as difficulty in exhaling against the applied pressure. The difficulty in applying optimum pressure is that incidents of airway obstruction come and go through the course of a night's sleep. One solution is to try to find an optimum pressure for a particular patient and maintain that pressure. This method requires the patient's stay at a sleep clinic, where sleep specialists can monitor the patient's course of breathing throughout one or more night's sleep, prescribe the appropriate pressure for that patient, and then set the apparatus to deliver the appropriate pressure. This method is, of course, inconvenient as well as expensive to the patient and tends to be inaccurate, as a typical patient will not sleep the same when away from familiar bedding and surroundings.

Accordingly, it is desirable to be able to adjust the applied pressure without requiring the patient to attend at a sleep center. Various methods of in-home adjustments have been considered. One method generally thought to be effective is to monitor the patient to try to anticipate the onset of an obstructed airway, and to adjust the pressure in response. When an elevated upper airway resistance or flow obstruction is anticipated or underway, the apparatus increases the applied pressure. When the patient returns to normal sleep, the applied pressure is reduced. The problem then, is to determine when a flow obstruction is occurring or is about to occur. It is desired to anticipate correctly in order to avoid the problems set forth above for when too much or too little pressure is applied.

Various methods have been proposed to solve this problem. In U.S. Pat. No. 5,107,831 to Halpern, an apparatus monitors the airflow to the patient and posits an event of airway obstruction when the patient's breath fails to meet a predetermined threshold of flow rate or duration. In U.S. Pat. No. 5,1345,995 to Gruenke, an apparatus monitors the airflow to the patient and analyzes the shape of the flow versus time waveform. If the shape of this waveform tends to be flattened, that is, more similar to a plateau than to a sinusoid, the apparatus posits an event of airway obstruction. In U.S. Pat. No. 5,245,995 to Sullivan, an apparatus monitors the patient's sound with a microphone. If audible snores are detected, the apparatus posits an event of airway obstruction. Similarly, in U.S. Pat. No. 5,953,713 to Behbehani, an apparatus measures the total pressure within an interface placed over a patient's airway and inputs frequency data in the range 100 to 150 Hz into a neural network to determine the presence of a pharyngeal wall vibration (a snore) which, according to Behbehani, is a precursor to sleep disorder breathing.

These methods have not proven totally satisfactory in controlling the applied pressure during PAP therapy. For example, the '713 patent, by measuring in the range of 100 to 150 Hz, essentially tests for snoring and does not measure or analyze any information concerning partial airway obstruction (as described within the present application), as this information is found in the lower frequency range 0 to 25 Hz. FIGS. 1 and 2 are plots in the frequency domain of energy v. frequency of typical breathing. As can be seen, there is a marked difference between normal breathing and breathing characterized by a partial airway obstruction, all in low frequencies. The present application exploits this difference to control the delivery of therapeutic gas.

Moreover, the methods of the prior art are unsatisfactory in analyzing a signal in a high-noise environment. The inventors herein have discovered an alternate way to detect the onset of an event of airway obstruction and to control the applied pressure from a high-noise signal such as results from a person's breathing over the course of a night. Accordingly, the method and apparatus of the present invention fulfill the need for analyzing a signal from a patient in order to control the applied pressure during PAP therapy.

SUMMARY

The present invention in one embodiment is a method of controlling positive airway pressure therapy by providing a flow of gas to a patient's airway at a pressure, obtaining information from the frequency range of zero to 25 HZ in the frequency domain of the flow, and adjusting the pressure based on the information. In another embodiment, the present invention is an apparatus for providing controlled positive airway pressure therapy, having a blower for providing a flow of gas to a patient's airway, a sensor to measure a characteristic of the flow, a controller to obtain information from the frequency range of zero to 25 HZ in the frequency domain of the characteristic, and a pressure regulator for adjusting the pressure based on the information.

BRIEF DESCRIPTION OF THE DRAWINGS

The organization and manner of the structure and operation of the invention, together with further objects and advantages thereof, may best be understood by reference to the following description, taken in connection with the accompanying drawings, wherein like reference numerals identify like elements in which:

FIG. 1 is a plot in the frequency domain of energy v. frequency for normal breathing and breathing characterized by partial airway obstruction;

FIG. 2 is also a plot in the frequency domain of energy v. frequency for normal breathing and breathing characterized by partial airway obstruction;

FIG. 3 is a diagram of an exemplary positive airway pressure apparatus of the preferred embodiment of the present invention;

FIG. 4 is a block diagram of the main algorithm of the method of the preferred embodiment of the present invention, showing the interaction of the five algorithms;

FIG. 5 is a block diagram of the Breath Detection Algorithm of the preferred embodiment of the present invention;

FIG. 6 is a block diagram of the Partial Airway Obstruction Algorithm of the preferred embodiment of the present invention;

FIG. 7 is a block diagram of the Apnea Detection Algorithm of the preferred embodiment of the present invention;

FIG. 8 is a block diagram of the Hypopnea Detection Algorithm of the preferred embodiment of the present invention;

FIGS. 9a, 9b, 9c, and 9d are block diagrams of the Pressure Adjusting Algorithm of the preferred embodiment of the present invention;

FIG. 10 is a diagram of airflow versus time, illustrating T_(start) and M_(f); and

FIG. 11 is a diagram of airflow versus time, illustrating T_(end), t₁, t₂ and M_(t1-t2).

DETAILED DESCRIPTION OF THE INVENTION

While the invention may be susceptible to embodiment in different forms, there is shown in the drawings, and herein will be described in detail, a specific embodiment with the understanding that the present disclosure is to be considered an exemplification of the principles of the invention, and is not intended to limit the invention to that as illustrated and described herein.

A positive airway pressure apparatus 100 of the preferred embodiment of the present invention is shown in FIG. 3 in which the patient 1 receives humidified, pressurized gas through an inspiratory conduit 3. It should be understood that the delivery systems could be CPAP (Continuous Positive Airway Pressure), VPAP (Variable Positive Airway Pressure), BiPAP (Bi-level Positive Airway Pressure), or any of numerous other forms of respiratory therapy. The apparatus 100 and method 200 of the present invention will be described as used for CPAP but an artisan of ordinary skill in the art will readily adapt both for use with VPAP, BiPAP, or another positive airway pressure therapeutic system.

Inspiratory conduit 3 is attached at one end to a mask 2, preferably one such as is described in U.S. Pat. No. 6,662,803. Inspiratory conduit 3 connects at its other end to the outlet 4 of a humidification chamber 5, which contains a volume of water 6. Inspiratory conduit 3 may contain heating heater wires (not shown) or other suitable heating elements that heat the walls of the conduit to reduce condensation of humidified gases within the conduit. Humidification chamber 6 is preferably formed from a plastic material and may have a highly heat-conductive base (for example an aluminum base) that is in direct contact with a heater plate 7 of humidifier 8.

Electronic controller 9 controls the various components of the apparatus 100. Controller 9 may be a microprocessor-based controller containing, as is well known in the art, RAM, ROM, an ALU, one or more registers, a data bus, counters (including at least a breath number counter 120 and a pressure decrease counter 130), and one or more buffers (including at least a circular buffer 110). Controller 9 executes computer software commands stored in its RAM and ROM.

Controller 9 receives input from sources such as user input dial 10 through which a user of the device may, for example, set a predetermined required value (preset value) of various characteristics of the gases supplied to the patient 1, such as initial airflow, pressure, humidity, or temperature of the gases. Controller 9 preferably receives input relating to airflow from differential pressure sensor 11, which is preferably located in blower 15. Differential pressure sensor 11 could alternatively be located elsewhere, upstream of mask 2, such as within conduit 3 or anywhere on mask 2. Alternatively, controller 9 may receive input related to airflow by direct measurement of flow at any point from blower 15 to mask 2. Controller 9 may also receive input from other sources, for example temperature sensors 12 through connector 13 and heater-plate temperature sensor 14.

In response to the user-set inputs and the other inputs, controller 9 determines when (or to what level) to energize heater plate 7 to heat the water 6 within humidification chamber 5. As the volume of water 6 within humidification chamber 5 is heated, water vapor begins to fill the volume of the chamber 5 above the water's surface and is passed out of the outlet 4 of humidification chamber 5 with the flow of gases (for example air) provided from a gas supply device such as blower 15, which gases enter the chamber 5 through inlet 16. Exhaled gases from the patient 1 are passed directly to ambient surroundings in FIG. 3.

Blower 15 is provided with a variable-pressure regulating device such as variable speed fan 21, which draws air or other gases through blower inlet 17. The speed of variable speed fan 21 is controlled by electronic controller 9 in response to inputs from the various components of apparatus 100 and by a user-set predetermined required value (preset value) of pressure or fan speed via dial 19.

Controller 9 is programmed with five algorithms:

1. Breath Detection Algorithm;

2. Apnea Detection Algorithm;

3. Hypopnea Detection Algorithm;

4. Partial Airway Obstruction Detection Algorithm; and

5. Pressure Adjusting Algorithm.

These algorithms interact as diagramed in FIG. 4. When the patient 1 turns on the apparatus 100, the controller 9 receives data from pressure sensor 11 and starts the main algorithm (step 200). Pressure sensor 11 is preferably a differential pressure sensor, and controller 9 converts differential pressure data to airflow data. Controller 9 samples the raw analogue flow signal at 50 Hz (step 202) and calculates bias flow (step 204). Bias flow, such as occurs from leaks in the mask 2 or elsewhere in the apparatus 100, is obtained preferably via a Butterworth low-pass filter (with a rise time of approximately thirty seconds). The information stored in circular buffer 110 in controller 9 is therefore net airflow data, as the controller 9 removes the bias flow (step 206). Circular buffer 110 in controller 9 is continuously updating data and storing that data for 15 seconds (step 208). Accordingly, throughout these algorithms, the flow being analyzed does not contain the bias flow. That is, the flow oscillates about zero flow.

The incoming flow data is continuously checked for the presence of a leak (step 210). If a significant leak is detected the algorithm is paused until the leak is resolved.

If there are no leaks and fewer than ten breaths have passed, the current data is analyzed by the Breath Detection Algorithm (step 300), as will be described in connection with FIG. 5. The Breath Detection Algorithm determines where the oldest breath begins and ends.

If no breath is detected (step 212), the main algorithm starts over with sampling the raw analogue flow signal (step 202). If a breath is detected (step 212), a breath number counter 120 is incremented (step 214), and the main algorithm starts over with sampling the raw signal (step 202).

Since it is assumed that the patient 1 will breathe a minimum of ten breaths before any apneas or hypopneas occur, the main algorithm of the preferred embodiment counts to determine if at least ten breaths have occurred (step 216). If more than ten breaths have occurred, the apparatus proceeds to the Apnea Detection Algorithm (step 500), as will hereinafter be described in connection with FIG. 7. If fewer than ten breaths have occurred, circular buffer 110 in controller 9 continues to sample raw analogue data (step 202).

Once ten breaths have occurred, the main algorithm proceeds as diagramed in FIG. 4. The Apnea Detection Algorithm (step 500) constantly checks the real-time incoming flow to see if an apnea is occurring (step 218), as will be described in greater detail in connection with FIG. 7. If an apnea is occurring, the Pressure Adjusting Algorithm (step 700) is called, as will be described in connection with FIG. 9. Once the apnea has finished (step 220), the main algorithm starts over with sampling raw data (step 202). If no apnea is occurring, the Breath Detection Algorithm (step 300) is called.

If no new breath has been detected (step 222), the algorithm checks to see if 2.5 minutes have passed since the last partial obstruction or apnea (step 224). If not, the main algorithm starts over with sampling raw data (step 202). If so, the Pressure Adjusting Algorithm (step 700) is called. If a breath is detected, the Hypopnea Detection Algorithm is called (step 600), as will be described in connection with FIG. 8, followed by the Partial Airway Obstruction Algorithm (step 400) as will be explained in connection with FIG. 6.

The Hypopnea Detection Algorithm (step 600) checks to see if a breath is possibly part of a hypopnea. The Partial Airway Obstruction Algorithm (step 400) is called to check for partial airway obstruction (step 232). If the Hypopnea Detection Algorithm finds that a hypopnea has occurred (step 226), the main algorithm checks to see if any breaths in the hypopnea showed partial airway obstruction (step 228). If so, the Pressure Adjusting Algorithm is called (step 700). If not, the main algorithm checks to see if 2.5 minutes have passed since the last partial obstruction or apnea event (step 230). If so, the Pressure Adjusting Algorithm is called (step 700). If not, the main algorithm starts over with sampling raw data (step 202).

The Partial Airway Obstruction Algorithm checks for partial airway obstruction (step 232) in the event a hypopnea has not occurred. If the current breath shows a partial airway obstruction, the main algorithm checks to see if the previous two breaths have shown a partial airway obstruction (step 234). If so, the Pressure Adjusting Algorithm (step 700) is called. If the current breath does not show a partial airway obstruction (step 232) or if the previous two breaths do not show a partial airway obstruction (step 234), the main algorithm checks to see if 2.5 minutes have passed since the last partial obstruction or apnea event (step 224). If so, the Pressure Adjusting Algorithm (step 700) is called; if not, the main algorithm starts over with sampling raw data.

Using the above algorithms, the applied positive airway pressure is at the lowest pressure required by the patient 1 to achieve therapeutic treatment. The details of the algorithms will now be explained.

Breath Detection Algorithm

Two routines are used, as diagramed in FIG. 5, depending on how many breaths have been detected since the program was initiated. The two routines differ, in that one incorporates the breathing period of the patient 1.

The Breath Detection Algorithm (step 300) initially determines if a previous breath's end is still contained within the flow buffer (step 302). If a previous breath's end point is still in the flow buffer, the start of the next breath (beginning of inspiration, or T_(start)) will be the data point following the end point of the previous breath (step 304). If the previous breath's end point is not in the buffer (such as if an apnea occurred), the new end point is determined, once a piece of flow data greater than five liters per minute is immediately followed by a piece of flow data less than 5 liters per minute has occurred (step 306), by searching the flow buffer to find E_(f) where E_(f) is 0.15 times the maximum flow in the buffer (step 308), and where flow is increasing, that is, flow is less than E_(f) followed by flow greater than E_(f) (step 310). The new end point T_(end) is then set as the start of the next breath (step 304).

At this point, the algorithm determines whether more than twenty breaths have occurred (step 312). If so, the algorithm searches to find M_(f), the maximum flow over the last one-quarter of the average breathing period after T_(start) (step 314). If twenty or fewer breaths have occurred, M_(f) is defined as the maximum flow in the next second after T_(start) (step 316).

The end point of expiration, T_(end), is determined by searching between two reference points (step 318) (reference points t₁, t₂ are shown in FIG. 10, a plot of airflow to the patient, as determined from differential pressure sensor 11, versus time). Each reference point t₁, t₂ is identified by determining the occurrence of a flow data value greater than the reference value followed by a flow data value less than the reference value (steps 320, 322), where t₂ is after t₁, which is after T_(start).

The reference value is given by: reference value=0.2×M _(f) where M_(f) is the maximum flow in 0.25×average breathing period since the beginning of inspiration (as found in step 314).

M_(f) is illustrated in FIG. 10, also a plot of airflow to the patient 1, as determined from differential pressure sensor 11, versus time.

The period between t₁ and t₂ should be greater than 0.5 sec (step 326). If not, t₂ is found again (step 322). The maximum flow, greater than zero, between the two reference points t₁, t₂ is calculated and used to determine the end of expiration E_(f) (step 328). The end of expiration is: E _(f)=0.15×M _(t1-t2) where M _(t1-t2)=maximum flow between t ₁ and t ₂ M_(t1-t2), t₁, and t₂ are illustrated in FIG. 11.

A flow data value less than E_(f) immediately followed by a flow data value greater than E_(f) indicates the end of the breath T_(end) (step 330). The breath is therefore from T_(start) to T_(end) (step 332). The apparatus then stores the maximum flow M_(t1-t2), provided the breath is not part of a hypopnea, as determined by the Hypopnea Detection Algorithm (step 600), as will be hereinafter described, and stores the period of the breath (step 334).

The period of the breath and the maximum inspiratory flow are used by the Apnea Detection Algorithm (step 500) and the Hypopnea Detection Algorithm (step 600), as will be described.

Partial Airway Obstruction Algorithm

The Partial Airway Obstruction Detection Algorithm (step 400) is diagramed in FIG. 6. It analyzes a breath, previously detected by the Breath Detection Algorithm (step 300), for the presence of a partial airway obstruction (partial obstruction of the upper airway).

When the patient 1 breathes, pressure gradients are generated between the lungs and atmosphere. The physiology of the upper airway combined with these pressure gradients and Bernoulli's Effect can result in partial collapse of the upper airway during inspiration. This partial collapse is prevalent in people with obstructive sleep apnea.

In order to determine if a breath contains a partial airway obstruction, Fourier analysis is used to analyze the inspiratory flow for features specific to partial airway obstruction. Once a signal has been mapped to the frequency domain via a Fourier transform, there are many ways to represent and analyze the frequency domain information. One could analyze the direct result of the Fourier transform, which would give the amplitude of the Fourier transform's sine component (information representative of the odd component of the original signal) and the amplitude of the Fourier transform's cosine component (information representing the even component of the original signal). Alternatively, from the Fourier transform, one could construct a phase v. frequency plot and an energy v. frequency plot (energy spectrum). The phase and energy information could be used to analyze the original waveform. An alternative to the energy v. frequency plot is to construct a magnitude v. frequency plot. In the preferred embodiment an energy spectrum is used to determine the presence of partial airway obstruction. Partial airway obstructions can be detected from analysis of the energy spectrum at low frequencies, as illustrated in FIGS. 1 and 2.

In particular, energy statements involving groupings of the frequency harmonics of the Fourier transform of the flow of therapeutic gas to the patient are generated from frequency-domain considerations. This technique allows analysis of signals that might have a considerable amount of background noise. All processing and analysis is done in the frequency domain based upon observed relationships between the patient's responses and the character of the energy spectrum in the frequency domain.

Additionally, severe airway obstruction often results in a reduced peak flow-rate during inspiration, which results in a prolongation of time spent inspiring relative to expiring. This increase in inspiratory time is incorporated in the Partial Airway Obstruction Detection Algorithm.

To obtain information solely from the inspiratory phase of the respiratory cycle, Fourier analysis is performed on a waveform consisting of two inspiratory phases oppositely combined. The result is an odd function defined as f(−x)=−f(x)  (1)

The standard Fourier series definition is

$\begin{matrix} {{f(x)} = {\frac{A_{0}}{2} + {\sum\limits_{n = 1}^{\infty}\left( {{A_{n}\cos\frac{n\;\pi\; x}{T}} + {B_{n}\sin\frac{n\;\pi\; x}{T}}} \right)}}} & (2) \end{matrix}$ where n is the number of harmonics, A_(n) are the harmonic cosine coefficients, B_(n) are the harmonic sine coefficients, and T is the period of cycle. Modifying Equation (2) according to Equation (1) gives

$\begin{matrix} {{f(x)} = {\sum\limits_{n = 1}^{\infty}{B_{n}\sin\frac{n\;\pi\; x}{T}}}} & (3) \end{matrix}$ as all A_(n), which represent the even part of the function, are zero.

To apply Fourier analysis to the inspiratory waveform, the algorithm of the preferred embodiment of the present invention first samples the incoming flow signal. Inspiration is then separated from expiration and manipulated as in Equation (1) to give a vector of N data points, y=[y₁ y₂ . . . y_(N)], that represent a single period of a cyclic function. The data is sampled evenly in time, hence t_(j±1)=τj where τ is the sampling interval between data points j=0, −1. The discrete Fourier transform of y is defined as

$\begin{matrix} {Y_{k + 1} = {\sum\limits_{j = 0}^{N - 1}{y_{j + 1}e^{{- 2}\pi\;{{ijk}/N}}}}} & (4) \end{matrix}$ where i is the square root of negative one and k=0, . . . , N−1. Each point Y_(k±i) of the transform has an associated frequency, f _(k+1) =k/τN  (5)

In the preferred embodiment, the fundamental frequency, k=1, is defined as f₂=1/τN and the first harmonic frequency, k=2, is defined as f₃=2/τN.

In order to determine whether a breath is a partial airway obstruction, the relative energy of specific frequencies and groups of frequencies is analyzed. To do this the energy spectrum is calculated, W _(k+1) =|Y _(k+1)|²  (6) and normalized such that the total energy equals one.

In the preferred embodiment, the first 13 harmonics are considered for analysis, as the relative power in the higher harmonics is minuscule. The analyzed harmonics are in the frequency range of zero to 25 Hz. The energy distribution of an inspiratory contour of a normal breath generally will have a majority of energy situated at W₂, which is associated with the fundamental frequency, and a small amount of energy is distributed among the harmonics. The present invention uses this characteristic of the energy spectrum as developed through Fourier analysis to posit that if the relative energy situated at a particular frequency or group of frequencies is above an empirically-observed threshold, the breath is deemed to be a partial airway obstruction.

Generally, for a normal breath the percentage of time spent inspiring is 40 percent and expiring is 60 percent. The patient 1 with a partially collapsed airway cannot achieve maximum inspiratory flow. Accordingly, the patient 1 extends the time spent inspiring relative to expiring. The time spent inspiring increases to 50 percent or more of the total breath during a partial airway obstruction.

Accordingly, the Partial Airway Obstruction Detection Algorithm first calculates an initial ratio, I_(insp), which is the portion of the entire breath spent on inspiration greater than the mean (step 402). Note that bias flow has been previously removed (steps 204, 206), so the mean of the breath should be zero or very close to zero. Next, the algorithm determines the inspiratory part of the breath and constructs a waveform consisting of two inspiratory phases oppositely combined (step 404). Then, the algorithm calculates the discrete energy spectrum of the oppositely combined waveform as a function of frequency f (step 406): W(f)=|FFT(waveform)|²

It is assumed that no significant energy is contained in the frequencies (or harmonics) above a predetermined level, preferably 13 times the fundamental frequency. Therefore, the energy spectrum is only retained, in the preferred embodiment, up to 13 times the fundamental frequency (step 408). Next, the algorithm normalizes the energy spectrum such that the total energy equals one (step 410): normalized energy spectrum=W(f)/ΣW(F)

This calculation is done so that all breaths will be analyzed the same, even though each breath may differ from another breath in duration, tidal volume, and maximum flow.

Next, the algorithm groups energies corresponding to different harmonic frequencies into information-bearing values (step 412). These information-bearing values are compared to threshold values that are calculated in accordance with the percentage of the breath that is spend on inspiration (step 414). The information-bearing values and the threshold values are determined empirically.

In the preferred embodiment, four information-bearing values are used: W_(first), W_(second), W_(freq), and W_(high_freq), as follows:

W_(first) = W₃ W_(second) = W₄ $W_{freq} = {\sum\limits_{k = 2}^{14}W_{k + 1}}$ $W_{high\_ freq} = {\sum\limits_{k = 6}^{14}W_{k + 1}}$ According, W_(first) corresponds to the energy in the first harmonic, W_(second) corresponds to the energy in the second harmonic, W_(freq) corresponds to the energy in the first 13 harmonics, and W_(high_freq) corresponds to the energy in the harmonics five through 13. Other information-bearing values can be obtained from the energies corresponding to different harmonic frequencies using other mathematical operations.

In the preferred embodiment, two thresholds are used, T_(freq) and T_(high_freq). These values vary depending on the value of I_(insp), the percentage of the breath spend inspiring (calculated at step 402) and have been determined empirically to be:

Threshold I_(insp) Value T_(freq) I_(insp) ≤ 40 0.15 T_(freq) 40 < I_(insp) 50 −0.005 × I_(insp) + 0.35 T_(freq) I_(insp) ≥ 50 0.1  T_(high) _(—) _(freq) I_(insp) ≤ 40 0.03 T_(high) _(—) _(freq) 40 < I_(insp) 60 −0.001 × I_(insp) + 0.07 T_(high) _(—) _(freq) I_(insp) ≥ 60 0.01

Using these empirically-determined values, the algorithm computes the information-bearing summations to the thresholds. If W_(second) is greater than or equal to 0.1 (step 416), the breath is a partial airway obstruction (step 418). If W_(first) is greater than or equal to 0.02, W_(second) is greater than or equal to 0.02, and W_(freq) is greater than or equal to 0.12 (step 420), the breath is a partial airway obstruction (step 422). If the sum of W_(first) and W_(second) is greater than or equal to 0.06 and W_(freq) is greater than or equal to 0.12 (step 424), the breath is a partial airway obstruction (step 426). If the sum of W_(first) and W_(second) is greater than or equal to 0.07 and W_(freq) is greater than or equal to 0.11 (step 428), the breath is a partial airway obstruction (step 430). If W_(freq) is greater than or equal to T_(freq) (step 432), the breath is a partial airway obstruction (step 434). If W_(high_freq) is greater than or equal to T_(high_freq) (step 436), the breath is a partial airway obstruction (step 438). If none of these comparisons is true, the breath is normal (step 440).

Apnea Detection Algorithm

The Apnea Detection Algorithm (step 500) is diagramed in FIG. 7. In order to detect an apnea (cessation of flow), the controller 9 compares the incoming flow data (minus bias flow) with a threshold, determined by the previous peak inspiratory flow. The Breath Detection Algorithm (step 300) had previously stored the maximum or peak inspiratory flow, not part of a hypopnea. The Apnea Detection Algorithm calculates the threshold, μ₁, as 20 percent of the average peak inspiratory flow of the oldest five breaths of the last ten breaths (step 502). The algorithm then calculates T_(apnea) (step 504): T _(apnea)=1.7×(breathing period averaged over last 50 breaths) T_(apnea), however, must be between ten and fifteen seconds.

If the incoming flow is less than the threshold, μ₁, an apnea may be occurring. If this condition is met for time greater than T_(apnea) (step 506), then an apnea is occurring (step 508), otherwise, no apnea occurred (step 510). If an apnea is occurring, the algorithm checks to see when the flow has increased to more than the threshold, μ₁ (step 512), indicating that the apnea has finished.

Hypopnea Detection Algorithm

In order to detect a hypopnea (reduction of flow), the Hypopnea Detection Algorithm (step 600), as diagramed in FIG. 8, compares the stored breath with a threshold, μ₂, determined by the previous peak inspiratory flow (step 602). Similar to the Apnea Detection Algorithm (step 500), the threshold, μ₂, is calculated from the peak inspiratory flow for the oldest five breaths of the last ten that did not constitute part of a hypopnea. The threshold (μ₂) is then taken as 60 percent of the average peak inspiratory flow of the oldest five breaths (step 602).

If incoming flow is less than the threshold (μ₂), for a period of time greater than 12 seconds (step 604), then a possible hypopnea has occurred; otherwise, no hypopnea is occurring (step 606). For the event to be classified as a hypopnea, there must be an increase in flow such that flow is greater than μ₂ within 30 seconds since the flow was less than μ₂ (step 608). If this increase in flow is detected, a hypopnea occurred (step 610); otherwise, the event was not a hypopnea (step 612).

Pressure Adjusting Algorithm

If an apnea was detected during the Apnea Detection Algorithm (step 500), the Pressure Adjusting Algorithm (step 700) is called. Also, if a hypopnea was detected during the Hypopnea Detection Algorithm (step 600), and there were partial airway obstruction breaths in the hypopnea (step 228), or if there was no hypopnea but the current breath and two previous breaths were partial airway obstructions (steps 226, 232, 234), the Pressure Adjusting (step 700) algorithm is called. If there was no hypopnea, and either the current breath does not show a partial airway obstruction or the previous two breaths did not show a partial airway obstruction, but is has been 2.5 minutes since the last partial airway obstruction (steps 226, 232, 234, 224), the Pressure Adjusting Algorithm is called. Also, if there was a hypopnea, but without any partial airway obstruction breaths, and it has been longer than a predetermined period since the last partial airway obstruction event or apnea, preferably 2.5 minutes (steps 226, 228, and 230), the Pressure Adjusting Algorithm (step 700) is called. The Pressure Adjusting Algorithm is diagramed in FIGS. 9a through 9 d.

The Pressure Adjusting Algorithm (step 700) determines whether to adjust the pressure and by how much, in order to control the therapeutic pressure delivered to the patient. As an initial rule of the preferred embodiment, this algorithm will only increase pressure to a maximum of 10 cm H₂O on an event classified as an apnea (step 702).

The algorithm first checks to determine if there have been any pressure decreases since the beginning of the period of sleep (step 704). If there have not been any such decreases, the algorithm determines if an obstructive event of any sort has been detected and whether the pressure is under a predetermined maximum, preferably ten cm H₂O (step 706). If these conditions are met, the algorithm determines whether the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with a partial airway obstruction (step 708). In the event of a hypopnea with a partial airway obstruction, the controller 9 increases pressure by one cm H₂O (step 710) and waits ten seconds before allowing another pressure change (step 712). If the event was an apnea, the controller 9 increases pressure by two cm H₂O (step 714) and waits 60 seconds before allowing another pressure change (step 716). If the event was a partial airway obstruction, the controller 9 increases pressure by one cm H₂O (step 718) and waits ten seconds before allowing another pressure change (step 720).

If there have been previous pressure decreases since the beginning of the period of sleep (step 704), or if the conditions of a detected obstructive event and the pressure being less than ten cm H₂O have not been met (step 706), the algorithm determines if there have been six consecutive pressure decreases. If so, total consecutive pressure-decrease counter 130 is reset to zero (step 722).

The algorithm next determines if there has been normal breathing for a predetermined period of time, preferably 2.5 minutes (step 724). If so, the controller 9 decreases the pressure by 0.5 cm H₂O (step 726) (and increments pressure-decrease counter 130 by one).

If there has not been normal breathing for the predetermined period of time (step 724), then either a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction has occurred (step 728). The next step depends on the previous pressure changes. If the previous consecutive pressure changes have been increases totaling greater than or equal to a total of one cm H₂O, and the current pressure is less than ten cm H₂O (step 730), the algorithm proceeds to step 708 as described above. If not, the controller 9 proceeds to increase the pressure by an amount depending on the nature of the obstructive event and the amount of previous pressure decreases, as diagramed in FIGS. 9b, 9c , and 9 d.

If the total previous pressure decreases were more than one cm H₂O (step 732), the algorithm determines if the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction (step 734). In the event of a hypopnea with a partial airway obstruction, the controller 9 increases pressure by one cm H₂O (step 736) and waits ten seconds before allowing another pressure change (step 738). If the event was an apnea, the controller 9 increases pressure by two cm H₂O (step 740) and waits 60 seconds before allowing another pressure change (step 742). If the event was a partial airway obstruction, the controller 9 increases pressure by 0.5 cm H₂O (step 744) and waits ten seconds before allowing another pressure change (step 746).

If the previous pressure decreases were more than one cm H₂O but not more than 1.5 cm H₂O (step 748), the algorithm determines if the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction (step 750). In the event of a hypopnea with partial airway obstruction, the controller 9 increases pressure by one cm H₂O (step 752) and waits ten seconds before allowing another pressure change (step 754). If the event was an apnea, the controller 9 increases pressure by two cm H₂O (step 756) and waits 60 seconds before allowing another pressure change (step 758). If the event was a partial airway obstruction, the controller 9 increases pressure by 0.5 cm H₂O (step 760) and waits ten seconds before allowing another pressure change (step 762).

If the previous pressure decreases were more than 1.5 cm H₂O but not more than two cm H₂O (step 764) (FIG. 9c ), the algorithm determines if the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction (step 766). In the event of a hypopnea with partial airway obstruction, the controller 9 increases pressure by 1.5 cm H₂O (step 768) and waits ten seconds before allowing another pressure change (step 770). If the event was an apnea, the controller 9 increases pressure by two cm H₂O (step 772) and waits 60 seconds before allowing another pressure change (step 774). If the event was a partial airway obstruction, the controller 9 increases pressure by one cm H₂O (step 776) and waits ten seconds before allowing another pressure change (step 778).

If the previous pressure decreases were more than two cm H₂O but less than or equal to 3.5 cm H₂O (step 780), the algorithm determines if the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction (step 782). In the event of a hypopnea with partial airway obstruction, the controller 9 increases pressure by 1.5 cm H₂O (step 784) and waits ten seconds before allowing another pressure change (step 754). If the event was an apnea, the controller 9 increases pressure by two cm H₂O (step 788) and waits 60 seconds before allowing another pressure change (step 790). If the event was a partial airway obstruction, the controller 9 increases pressure by 1.5 cm H₂O (step 792) and waits ten seconds before allowing another pressure change (step 794).

If the previous pressure decreases were more than 3.5 cm H₂O (step 796), the algorithm determines if the obstructive event was a partial airway obstruction, an apnea, or a hypopnea with partial airway obstruction (step 798). In the event of a hypopnea with partial airway obstruction, the controller 9 increases pressure by one-half the total pressure decrease (step 800) and waits ten seconds before allowing another pressure change (step 802). If the event was an apnea, the controller 9 increases pressure by one-half the total pressure decrease (step 804) and waits 60 seconds before allowing another pressure change (step 806). If the event was a partial airway obstruction, the controller 9 increases pressure by one-half the total pressure decrease (step 808) and waits ten seconds before allowing another pressure change (step 810).

While preferred embodiments of the present invention are shown and described, it is envisioned that those skilled in the art may devise various modifications of the present invention without departing from the spirit and scope of the appended claims. 

What is claimed is:
 1. A method of controlling positive airway pressure therapy, comprising: providing gas to an airway of a patient at a pressure; determining a flow of the gas provided to the airway of the patient; detecting hypopnea based in part on determining that the flow falls below a hypopnea entry flow threshold and that the flow subsequently exceeds a hypopnea exit flow threshold within a maximum time duration, wherein the hypopnea entry and hypopnea exit flow thresholds are based at least in part on a plurality of previous flow values of the gas provided to the airway of the patient; and increasing the pressure of the gas in response to detecting the hypopnea, the increasing comprising, in response to detecting that the hypopnea was preceded by a pressure decrease: increasing the pressure of the gas by a first magnitude in response to determining that a magnitude of the pressure decrease does not satisfy a threshold; and increasing the pressure of the gas by a second magnitude in response to determining that the magnitude of the pressure decrease satisfies the threshold, the second magnitude being larger than the first magnitude, and the second magnitude being proportional to the magnitude of the pressure decrease.
 2. The method of claim 1, further comprising detecting occurrence of a current breath in the flow of gas, wherein determining that the flow falls below the hypopnea entry flow threshold comprises determining that a flow value of the current breath falls below the hypopnea entry flow threshold.
 3. The method of claim 1, wherein detecting the hypopnea further comprises determining that the flow does not exceed a minimum flow threshold for a minimum predetermined duration of time, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 4. The method of claim 1, wherein the flow falling below the hypopnea entry flow threshold indicates a potential start of hypopnea, and the flow exceeding the hypopnea exit flow threshold indicates a potential end of hypopnea, and wherein the detection of the hypopnea further requires that a time duration between the potential start of hypopnea and the potential end of hypopnea complies with a minimum time requirement.
 5. The method of claim 4, wherein detecting the hypopnea further comprises requiring flow values of current breaths between the potential start of hypopnea and the potential end of hypopnea to fall below a minimum flow threshold for at least the minimum time requirement, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 6. The method of claim 1, wherein the magnitude of the preceding pressure decrease comprises a sum of a plurality of preceding pressure decreases.
 7. A positive airway pressure therapy apparatus comprising: a blower configured to provide a flow of gas to an airway of a patient at a pressure; a sensor configured to monitor the flow of the gas; and a controller configured to: determine the flow of the gas based on an output of the sensor; detect hypopnea in response to a determination that the flow falls below a hypopnea entry flow threshold and that the flow subsequently exceeds a hypopnea exit flow threshold within a maximum time duration, wherein the hypopnea entry and hypopnea exit flow thresholds are based at least in part on a plurality of previous flow values of the gas provided to the airway of the patient; and cause increase of the pressure of the gas in response to the detection of the hypopnea, the controller further configured to, in response to a detection that the hypopnea has been preceded by a pressure decrease: cause increase of the pressure of the gas by a first magnitude in response to a determination that a magnitude of the pressure decrease does not satisfy a threshold; and cause increase of the pressure of the gas by a second magnitude in response to a determination that the magnitude of the pressure decrease satisfies the threshold, the second magnitude being larger than the first magnitude, and the second magnitude being proportional to the magnitude of the pressure decrease.
 8. The apparatus of claim 7, wherein the controller is further configured to: determine a total flow of the gas provided to the airway of the patient; determine a flow due to one or more leaks in a flow path of the gas; and subtract the flow due to one or more leaks from the total flow.
 9. The apparatus of claim 7, wherein the hypopnea entry and hypopnea exit flow thresholds are determined based at least in part on an average of flow values of a plurality of previous breaths outside the hypopnea, the average excluding one or more most recent breaths of the plurality of previous breaths.
 10. The apparatus of claim 9, wherein the hypopnea entry and hypopnea exit flow thresholds comprise a fraction of an average of the flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 11. The apparatus of claim 7, wherein the controller is further configured to detect occurrence of a current breath in the flow of gas, and wherein the determination that the flow falls below the hypopnea entry flow threshold comprises a determination that a flow value of the current breath falls below the hypopnea entry flow threshold.
 12. The apparatus of claim 7, wherein the controller is further configured to detect hypopnea based on a determination that the flow does not exceed a minimum flow threshold for a minimum predetermined duration of time, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 13. The apparatus of claim 7, wherein the determination that the flow falls below the hypopnea entry flow threshold indicates a potential start of hypopnea, and the determination that the flow exceeds the hypopnea exit flow threshold indicates a potential end of hypopnea, and wherein the detection of the hypopnea further requires that a time duration between the potential start of hypopnea and the potential end of hypopnea complies with a minimum time requirement.
 14. The apparatus of claim 13, wherein the detection of the hypopnea further requires that flow values of current breaths between the potential start of hypopnea and the potential end of hypopnea fall below a minimum flow threshold for at least the minimum time requirement, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 15. The apparatus of claim 7, wherein the controller is further configured to cause increase of the pressure of the gas based on a current pressure level.
 16. The apparatus of claim 7, wherein the magnitude of the preceding pressure decrease comprises a sum of a plurality of preceding pressure decreases.
 17. A positive airway pressure therapy apparatus comprising: a blower configured to provide a flow of gas to an airway of a patient at a pressure; a sensor configured to monitor the flow of the gas; and a controller configured to: determine the flow of the gas based on an output of the sensor; detect hypopnea in response to a determination that the flow falls below a hypopnea entry flow threshold and that the flow subsequently exceeds a hypopnea exit flow threshold within a maximum time duration, wherein the hypopnea entry and hypopnea exit flow thresholds are based at least in part on a plurality of previous flow values of the gas provided to the airway of the patient; and in response to the detection of the hypopnea and a determination that the hypopnea was preceded by a pressure decrease: cause increase of the pressure of gas by a preset pressure increase or a pressure increase determined based on a magnitude of the pressure decrease, the preset pressure increase being smaller than the pressure increase determined based on the magnitude of the pressure decrease, wherein a determination of whether to increase the pressure by the preset pressure increase or the pressure increase determined based on the magnitude of the pressure decrease is based on the magnitude of the pressure decrease.
 18. The apparatus of claim 17, wherein the pressure increase determined based on the magnitude of the pressure decrease is one-half of the magnitude of the pressure decrease.
 19. The apparatus of claim 17, wherein the hypopnea entry and hypopnea exit flow thresholds are determined based at least in part on an average of flow values of a plurality of previous breaths outside the hypopnea, the average excluding one or more most recent breaths of the plurality of previous breaths.
 20. The apparatus of claim 19, wherein the hypopnea entry and hypopnea exit flow thresholds comprise a fraction of an average of the flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 21. The apparatus of claim 17, wherein the controller is further configured to detect occurrence of a current breath in the flow of gas, and wherein the determination that the flow falls below the hypopnea entry flow threshold comprises a determination that a flow value of the current breath falls below the hypopnea entry flow threshold.
 22. The apparatus of claim 17, wherein the controller is further configured to detect hypopnea based on a determination that the flow does not exceed a minimum flow threshold for a minimum predetermined duration of time, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 23. The apparatus of claim 17, wherein the determination that the flow falls below the hypopnea entry flow threshold indicates a potential start of hypopnea, and the determination that the flow exceeds the hypopnea exit flow threshold indicates a potential end of hypopnea, and wherein the detection of the hypopnea further requires that a time duration between the potential start of hypopnea and the potential end of hypopnea complies with a minimum time requirement.
 24. The apparatus of claim 23, wherein the detection of the hypopnea further requires that flow values of current breaths between the potential start of hypopnea and the potential end of hypopnea fall below a minimum flow threshold for at least the minimum time requirement, the minimum flow threshold based at least in part on an average of flow values of a plurality of previous breaths, the average excluding one or more most recent breaths of the plurality of previous breaths.
 25. The apparatus of claim 17, wherein the controller is further configured to cause increase of the pressure of the gas based on a current pressure level.
 26. The apparatus of claim 17, wherein the magnitude of the pressure decrease comprises a sum of a plurality of preceding pressure decreases. 